﻿
<!doctype html>
<html>
<head>
<title>工人编辑</title> <#include "../../commonUse.html"/>

<script type="text/javascript"
	src="${ctx.contextPath}/js/jquery.form.js"></script>
<script
	src="${ctx.contextPath}/pages/business/worker/js/worker_detail.js"></script>
<script src="${ctx.contextPath}/js/validator.js"></script>
<script>
var sex = '${worker.SEX}';
var photo = '${worker.PHOTO}';
var edudegree = '${worker.EDUDEGREE}';
var worktype = '${worker.WORKTYPE}';
var chargetype = '${worker.CHARGETYPE}';
var groupId = '${worker.GROUPID}';
var payform = '${worker.PAYFORM}';
var recId='${worker.REC_ID}';
</script>

</head>
<body>
	<div class="smart-body">
		<div class="border1pxe6">
			<div class="layui-layer-title">工人详情</div>
			<div class="pad10">
			<div class="smart-tiptit">温馨提示：新增工人，客户端（APP）登录默认密码为手机号默认后6位</div>
			<form class="layui-form" id="form1" name="form1"
				enctype="multipart/form-data">
				<input type="hidden" id="recId" value="${worker.REC_ID}"
					name="recId"></input>
				<fieldset class="layui-elem-field layui-field-title">
					<legend>基本信息</legend>
					<div class="layui-field-box">
						<div class="smart-worker_base">

							<!--左边块-->
							<div class="smart-cell smart-cell_lt33">
								<div class="layui-form-item">
									<label class="layui-form-label">姓名<span class="empt">*</span></label>
									<div class="layui-input-inline">
										<input type="text" id="name" autocomplete="off"
											class="layui-input" name="name" maxlength="10" readonly
											value="${worker.NAME}" dataType="LimitA" min="1" max="20"
											msg="姓名不能为空且少于20个字节."></input>
									</div>
								</div>
								<div class="layui-form-item">
									<label class="layui-form-label">手机号<span class="empt">*</span></label>
									<div class="layui-input-inline">
										<input type="text" id="tel" name="tel" autocomplete="off"
											class="layui-input" maxlength="11" value="${worker.TEL}" readonly
											dataType="Mobile" msg="请输入手机号码！"></input>
									</div>
								</div>
								<div class="layui-form-item">
									<label class="layui-form-label">身份证号<span class="empt">*</span></label>
									<div class="layui-input-inline">
										<input type="text" id="idcard" name="idcard"
											autocomplete="off" class="layui-input"
											value="${worker.IDCARD}" maxlength="18" dataType="IdCard" readonly
											msg="请输入身份证号！"></input>
									</div>
								</div>
								<div class="layui-form-item">
									<label class="layui-form-label">籍贯</label>
									<div class="layui-input-inline">
										<input type="text" id="native" autocomplete="off" readonly
											value="${worker.NATIVE}" class="layui-input" name="native"
											maxlength="10"></input>
									</div>
								</div>
								<div class="layui-form-item">
									<label class="layui-form-label">地址</label>
									<div class="layui-input-inline">
										<input type="text" id="addr" autocomplete="off" readonly
											value="${worker.ADDR}" class="layui-input" name="addr"
											maxlength="25"></input>
									</div>
								</div>
								<div class="layui-form-item">
									<label class="layui-form-label">工资卡号</label>
									<div class="layui-input-inline">
										<input type="text" id="bankcard" autocomplete="off"
											value="${worker.BANKCARD}" class="layui-input" readonly
											name="bankcard" maxlength="20"></input>
									</div>
								</div>
								<div class="layui-form-item">
									<label class="layui-form-label">年龄<span class="empt">*</span></label>
									<div class="layui-input-inline">
										<input type="text" id="age" autocomplete="off" readonly
											value="${worker.AGE}" class="layui-input" name="age"
											maxlength="20" dataType="Number"></input>
									</div>
								</div>
							</div>
							<!--左边块 end-->

							<!--中间块-->
							<div class="smart-cell smart-cell_lt33">
								<div class="layui-form-item">
									<label class="layui-form-label">性别<span class="empt">*</span></label>
									<div class="layui-input-inline smart-form_cr">
										<input class="smart-body_radio" name="sex" type="radio"
											value='0'> <span>男</span> <input
											class="smart-body_radio" name="sex" value='1' type="radio">
										<span>女</span>
									</div>
								</div>
								<div class="layui-form-item">
									<label class="layui-form-label">民族</label>
									<div class="layui-input-inline">
										<select class="smart-body_select" name="nation" id="nation" readonly>
											<option value="">汉族</option>
										</select>
									</div>
								</div>
								<div class="layui-form-item">
									<label class="layui-form-label">文化程度<span class="empt">*</span></label>
									<div class="layui-input-inline">
										<select id="edudegree" name="edudegree" readonly
											class="smart-body_select">
											<option VALUE="1">小学</option>
											<option VALUE="2">初中</option>
											<option VALUE="3">高中</option>
											<option VALUE="4">中专</option>
											<option VALUE="5">大专</option>
											<option VALUE="6">本科</option>
											<option VALUE="7">研究生</option>
											<option VALUE="8">硕士</option>
										</select>
									</div>
								</div>
								<div class="layui-form-item">
									<label class="layui-form-label">当前工种<span class="empt">*</span></label>
									<div class="layui-input-inline">
										<select id="worktype" name="worktype"
											class="smart-body_select" dataType="LimitA" readonly msg="当前工种不能为空.">
											<option VALUE="木工">木工</option>
											<option VALUE="泥工">泥工</option>
											<option VALUE="电焊工">电焊工</option>
											<option VALUE="架子工">架子工</option>
										</select>
									</div>
								</div>
								<div class="layui-form-item">
									<label class="layui-form-label">入职时间</label>
									<div class="layui-input-inline">
										<input readonly="readonly" name="entrytime" autocomplete="off"
											class="layui-input" id="entrytime" type="text" readonly
											value="${worker.ENTRYTIME}" dataType="LimitA" msg="入职时间不能为空."
											onclick="WdatePicker({lang:'zh-cn'})" />
									</div>
								</div>
								<div class="layui-form-item">
									<label class="layui-form-label">工号<span class="empt">*</span></label>
									<div class="layui-input-inline">
										<input type="text" id="jobno" name="jobno" autocomplete="off"
											value="${worker.JOBNO}" class="layui-input" maxlength="20" readonly
											dataType="LimitA" min="1" max="20" msg="工号不能为空且少于20个字节."></input>
									</div>
								</div>
								<div class="layui-form-item">
									<label class="layui-form-label">在册年龄<span class="empt">*</span></label>
									<div class="layui-input-inline">
										<input type="text" id="registeredAge" name="registeredAge"
											value="${worker.REGISTEREDAGE}" autocomplete="off" readonly
											class="layui-input" maxlength="20" dataType="Number"></input>
									</div>
								</div>
								<div class="layui-form-item">
									<label class="layui-form-label"><span class="empt">*</span>班组：</label>
									<div class="layui-input-inline" id='group'>
										
									</div>
								</div>
							</div>
							<!--中间块 end-->

							<!--右边图片块-->
							<div class="smart-cell smart-cell_rt">
								<div class="smart-worker_header">
									<div class="site-demo-upload">
										<img id="LAY_demo_upload" src=""> <input type="hidden"
											value="" name="photoPath" id="photoPath"
											value="${worker.PHOTO}">
										<div class="site-demo-upbar">
											<!--<div class="layui-box layui-upload-button">
												 <input type="file" name="photo" id="photo"
													class="layui-upload-file"> <span
													class="layui-upload-icon"> <i class="layui-icon"></i>选择图片
												</span> 
											</div>-->
											<!-- <div class="layui-btn"
												style="position: relative; z-index: 20;"
												onClick="photoUpload();">上传</div> -->
										</div>
									</div>
								</div>
							</div>
							<!--右边图片块 end-->

							<div class="layui-form-item">
								<label class="layui-form-label">当前合同</label> <a id="file-name"></a>
								<div class="site-demo-upbar" style="display: inline-block;">
									<div id="contractList">
									</div>
							
								</div>
							</div>
							<!-- <div class="layui-form-item">
								<label class="layui-form-label">合同</label> <a id="file-name"></a>
								<div class="site-demo-upbar" style="display: inline-block;">
									<div class="layui-box layui-upload-button">
										<input onchange="uploadFile();" type="file" name="contract"
											id="contract" multiple="multiple" class="layui-upload-file">
										<span class="layui-upload-icon"> <i class="layui-icon">&#xe608;</i>上传附件
										</span>
									</div>
								</div>
							</div> -->

						</div>
					</div>
				</fieldset>


				<div class="smart-worker_more">
					<ul class="smart-worker_tabs clearfix">
						<li class="smart-tab-item active" id="tab_salary">薪酬配置</li>
						<li class="smart-tab-item" id="tab_jcqk">奖惩记录</li>
						<li class="smart-tab-item" id="tab_project">工程记录</li>
					</ul>
					<!-- 薪酬配置 -->
					<div class="smart-work_moreform" id="div_salary">
						<div class="layui-form-item">
							<div class="layui-inline">
								<label class="layui-form-label">基本工资</label>
								<div class="layui-input-inline">
									<input type="text" id="salary" autocomplete="off" readonly
										value="${worker.SALARY}" class="layui-input" name="salary"
										maxlength="20" style="width: 160px; display: inline-block;"
										dataType="Number"></input>
								</div>
							</div>
							<div class="layui-inline">
								<label class="layui-form-label">计费方式</label>
								<div class="layui-input-inline">
									 <select id="chargetype" name="chargetype" class="smart-body_select"
										dataType="LimitA" msg="计费方式不能为空." readonly>
										<option VALUE="0">按工程量</option>
										<option VALUE="1">按工程量</option>
										<option VALUE="2">按时</option>
										<option VALUE="3">按件</option>
									</select>
								</div>
							</div>
							<div class="layui-inline">
								<label class="layui-form-label">单位薪酬</label>
								<div class="layui-input-inline">
									<input type="text" id="unitpay" name="unitpay"
										value="${worker.UNITPAY}" autocomplete="off"
										class="layui-input" maxlength="20" readonly
										style="width: 160px; display: inline-block;" dataType="Number"></input>元
								</div>
							</div>
						</div>
						<div class="layui-form-item smart-layitem_custom">
							<label class="layui-form-label">补贴</label>
							<div class="layui-input-inline">
								<div class="smart-input-inline">
									<!-- <input type="checkbox" name="gwsubsidy_" value="" /> -->
									<span>高温补贴</span> <input type="text" autocomplete="off"
										value="${worker.GWSUBSIDY}" class="layui-input" readonly
										name="gwsubsidy" value="0" />元
								</div>
								<div class="smart-input-inline">
									<!-- <input type="checkbox" name="wcsubsidy_" value="" /> -->
									<span>午餐补贴</span> <input type="text" autocomplete="off"
										value="${worker.WCSUBSIDY}" class="layui-input" readonly
										name="wcsubsidy" value="0" />元
								</div>
								<div class="smart-input-inline">
									<!-- <input type="checkbox" name="qtsubsidy_" value="" /> -->
									<span>其他</span> <input type="text" autocomplete="off"
										value="${worker.QTSUBSIDY}" class="layui-input" readonly
										name="qtsubsidy" value="0" />元
								</div>
							</div>
						</div>
						<div class="layui-form-item smart-layitem_custom">
							<label class="layui-form-label">保险</label>
							<div class="layui-input-inline">
								<div class="smart-input-inline">
									<!-- <input type="checkbox" name="ylsafe_" value="" /> -->
									<span>养老险</span> <input type="text" autocomplete="off" readonly
										value="${worker.YLSAFE}" class="layui-input" name="ylsafe"
										value="0" />元
								</div>
								<div class="smart-input-inline">
									<!-- <input type="checkbox" name="sysafe_" value="" /> -->
									<span>失业险</span> <input type="text" autocomplete="off" readonly
										value="${worker.SYSAFE}" class="layui-input" name="sysafe"
										value="0" />元
								</div>
								<div class="smart-input-inline">
									<!-- <input type="checkbox" name="ywsafe_" value="" /> -->
									<span>意外险</span> <input type="text" autocomplete="off" readonly 
										value="${worker.YWSAFE}" class="layui-input" name="ywsafe"
										value="0" />元
								</div>
								<div class="smart-input-inline">
									<!-- <input type="checkbox" name="qtsafe_" value="" /> -->
									<span>其他</span> <input type="text" autocomplete="off" readonly
										value="${worker.QTSAFE}" class="layui-input" name="qtsafe"
										value="0" />元
								</div>
							</div>
						</div>
						<div class="layui-form-item smart-layitem_custom">
							<label class="layui-form-label">公积金</label>
							<div class="layui-input-inline">
								<div class="smart-input-inline">
									<!-- <input type="checkbox" name="gjj_" value="" /> -->
									<span>住房公积金</span> <input type="text" autocomplete="off" readonly
										value="${worker.GJJ}" class="layui-input" name="gjj" value="0" />元
								</div>
							</div>
						</div>
						<div class="layui-form-item smart-layitem_custom">
							<label class="layui-form-label">个税</label>
							<div class="layui-input-inline">
								<div class="smart-input-inline">
									<!-- <input type="checkbox" name="gs_" value="" /> -->
									<span>个人所得税</span> <input type="text" autocomplete="off" readonly
										value="${worker.GS}" class="layui-input" name="gs" value="" />元
								</div>
							</div>
						</div>
						<div class="layui-form-item smart-layitem_custom">
							<label class="layui-form-label">工资发放形式</label>
							<div class="layui-input-inline">
								<div class="smart-input-inline">
									<input type="radio" name="payform" value="0" readonly/> <span>现金</span>
									<input type="radio" name="payform" value="1" readonly/> <span>银行代发</span>
								</div>
							</div>
						</div>
					</div>
					<!-- 奖惩情况 -->
					<div id="div_jcqk">
						<table class="layui-table" lay-skin="line">
							<thead>
								<tr>
									<!-- <th class="smart-tb_checkbox"><input type="checkbox">
									</th> -->
									<th>时间</th>
									<th>工程项目</th>
									<th>奖惩类型</th>
									<th>奖惩级别</th>
									<th>事件描述</th>
									<th>处理结果</th>
									<th>状态</th>
								</tr>
							</thead>
							<tbody id="tbodyJcqkData">

							</tbody>
						</table>

					</div>
					<!-- 工程记录 -->
					<div id="div_project">
						<table class="layui-table" lay-skin="line">
							<thead>
								<tr>
									<!-- <th class="smart-tb_checkbox"><input type="checkbox">
									</th> -->
									<th>项目</th>
									<th>所属班组</th>
									<th>工种</th>
									<th>进场时间</th>
									<th>退场时间</th>
									<th>项目状态</th>
								</tr>
							</thead>
							<tbody id="tbodyData">

							</tbody>
						</table>
						<!--           ######分页开始 ######             -->
						<div class="tableData"></div>
						<!--           ######分页结束 ######              -->

					</div>
				</div>
				<!--   -->

				<div class="smart-footer_btn">
					<div class="layui-btn layui-btn-primary" onclick="closeW();">关闭</div>
				</div>

			</form>
			</div>
		</div>
	</div>

</body>
<script>
	
</script>

</html>